{include file="common/mate"}
<body>
	<!-- 头部 -->
    {include file="common/top"}
    <!-- /头部 -->
	
	<div class="main-container container-fluid">
		<div class="page-container">
			  <!-- Page Sidebar -->
            {include file="common/left"}
            <!-- Page Sidebar Header-->

            <!-- /Page Sidebar -->
            <!-- Page Content -->
            <div class="page-content">
                <!-- Page Breadcrumb -->
                <div class="page-breadcrumbs">
                    <ul class="breadcrumb">
                                        <li>
                        <a href="{:url('index/index')}">系统</a>
                    </li>
                                        <li class="active">链接列表</li>
                                        </ul>
                </div>
                <!-- /Page Breadcrumb -->

                <!-- Page Body -->
                <div class="page-body">
                    
<button type="button" tooltip="添加商品" class="btn btn-sm btn-azure btn-addon" onClick="javascript:window.location.href = '{:url('link/add')}'"> <i class="fa fa-plus"></i> Add
</button>
<div class="row">
    <div class="col-lg-12 col-sm-12 col-xs-12">
        <div class="widget">
            <div class="widget-body">
                <div class="flip-scroll">
                    <table class="table table-bordered table-hover">
                        <thead class="">
                            <tr>
                                <th class="text-center">ID</th>
                                <th class="text-center">链接名称</th>
                                <th class="text-center">链接网址</th>
                                <th class="text-center">链接LOGO</th>
                                <th class="text-center">链接状态</th>
                                <th class="text-center">链接描述</th>
                                <th class="text-center">链接类型</th>
                                <th class="text-center">操作</th>
                            </tr>
                        </thead>
                        <tbody>
                        {volist name="linkres" id="vo"}
                            <tr>
                                <td align="center">{$vo.id}</td>
                                <td align="center">{$vo.title}</td>
                                <td align="center"><a href="{$vo.link_url}" target="_blank">{$vo.link_url}</a></td>
                                 <td align="center">
                                     {if condition="$vo['logo'] neq ''"}
                                        <img src="__uploads__/{$vo.logo}" alt="" height="20"></td>
                                     {else}
                                        暂无LOGO
                                     {/if}
                                  <td align="center">
                                      {if condition="$vo['status'] eq 1"}
                                      <img src="__admin__/images/run.png" alt="" height="20">
                                      {else}
                                      <img src="__admin__/images/stop.png" alt="" height="20" style="margin-left: 5px;">
                                      {/if}
                                      </td>
                                   <td align="center">{$vo.desc|cut_str=###,10}</td>
                                   <td align="center">
                                       {if condition="$vo['type'] eq 0 "}
                                       图片
                                       {else/}
                                       文字
                                       {/if}
                                   </td>


                                <td align="center">
                                    <a href="{:url('link/edit',array('id'=>$vo['id']))}" class="btn btn-primary btn-sm shiny">
                                        <i class="fa fa-edit"></i> 编辑
                                    </a>

                                    <a href="#" onClick="warning('确实要删除吗', '{:url('link/del',array('id'=>$vo['id']))}')" class="btn btn-danger btn-sm shiny">
                                        <i class="fa fa-trash-o"></i> 删除
                                    </a>

                                </td>
                            </tr>
                        {/volist}

                         </tbody>
                    </table>
                </div>
                <div style="padding-top: 10px;text-align: right;">{$linkres->render()}</div>

                <div>
                	                </div>
            </div>
        </div>
    </div>
</div>

                </div>
                <!-- /Page Body -->
            </div>
            <!-- /Page Content -->
		</div>	
	</div>
    {include file="common/js"}
</body></html>